From bfaf6cc2b487f17b343b620993370e040efbcf90 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Thu, 22 Oct 2009 11:40:38 +0000 Subject: [PATCH] (bug 21222) Free tag if not using it. Patch by Platonides. --- RELEASE-NOTES | 2 ++ includes/parser/Parser.php | 7 +++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 87f8e67e91..3fe43f94ac 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -254,6 +254,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN reuploading. * Added $wgRateLimitsExcludedIPs, to allow specific IPs to be whitelisted from rate limits. +* (bug 21222) When $wgUseTeX is not enabled, is no longer registered with + the parser so extensions are free to implement their own tag === Bug fixes in 1.16 === diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index c96ada40b6..f1d8fcda63 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -3282,8 +3282,11 @@ class Parser $output = Xml::escapeTagsOnly( $content ); break; case 'math': - $output = $wgContLang->armourMath( - MathRenderer::renderMath( $content, $attributes ) ); + if ( $this->mOptions->getUseTeX() ) { + $output = $wgContLang->armourMath( + MathRenderer::renderMath( $content, $attributes ) ); + } + /* else let a tag hook handle it (bug 21222) */ break; case 'gallery': $output = $this->renderImageGallery( $content, $attributes ); -- 2.20.1